//
//  BusinessDetailheader.swift
//  ZNHXManagement
//
//  Created by 四川中农 on 2018/9/29.
//  Copyright © 2018年 四川中农. All rights reserved.
//

import UIKit

class BusinessDetailheader: UITableViewHeaderFooterView {

    /*
    // Only override draw() if you perform custom drawing.
    // An empty implementation adversely affects performance during animation.
    override func draw(_ rect: CGRect) {
        // Drawing code
    }
    */
    
    var titleLabel:UILabel!
    
    override init(reuseIdentifier: String?) {
        super.init(reuseIdentifier: reuseIdentifier)
        self.contentView.backgroundColor = UIColor.backgroundColor
        self.titleLabel = Utils.labelWith(frame: CGRect.init(x: 11, y: 0, width: UIScreen.ScreenWidth - 11, height: 45), font: UIFont.boldSystemFont(ofSize: 14), textAlignment: NSTextAlignment.left, textColor: "#000000", text: "")
        self.addSubview(self.titleLabel)
    }
    
    func getMonth(date:Date) ->Int {
        let calendar = Calendar.current
        let com = calendar.dateComponents([.month], from: date)
        return com.month!
    }

    required init?(coder aDecoder: NSCoder) {
        super.init(coder: aDecoder)
    }
}
